﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="ThreadPage.aspx.cs" Inherits="WebForum.ForumPages.PostPage" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        .style2
        {
            font-weight: normal;
            font-size: x-large;
            color: #333333;
            height: 40px;
        }
        .style3
        {
            color: #800000;
            text-transform: capitalize;
        }
        .response1, .response2
        {
            background-color: #EEEEEE;
            color: #000000;
            border-bottom: 2px solid #000833;
              padding: 5px;
              margin: 1px;
              font-family: helvetica;
              font-style: normal;
              font-weight: normal;
              font-size: 16px;
              font-variant: normal;
              text-align: left;
              width: 75%;
        }
        .response1 h1, .response2 h1
        {
            color: #000000;
            font-family: arial;
            font-style: italic;
            font-weight: bold;
            font-size: 20px;
        }
        .response1 h2, .response2 h2
        {
            color: #940000;
            font-family: 'times new roman';
            font-style: normal;
            font-weight: normal;
            font-size: 12px;
            text-transform: capitalize;
        }
        .response1 p, .response2 p
        {
            color: #292929;
            font-family: helvetica;
            font-style: normal;
            font-weight: normal;
            font-size: 16px;
        }
        .response2
        {
            background-color: #DCDCDC;
        }
        .titleBody 
        {
        }
        
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <p>
        <h1><strong style="font-weight: 700; color: #333333">Forum: <% =this.details[4]%> --> SubForum: <% =this.details[5]%> --> Thread: <% =this.details[0]%></strong> </h1>
        <%--<h3>Moderators: <% =this.details[1]%></h3>--%>
    </p>
    <p></p>
    <div id="thread">
        <h1 class="style2"><strong style="font-size: xx-large"> <% =this.details[0] %> </strong></h1>
        <span class="style3">by: <% =this.details[2] %>&nbsp;-&nbsp; <% =this.details[3] %>
        </span>
        <div class="titleBody">
            <p><% =this.details[1] %></p>
            <%--<asp:Label ID="Label8" runat="server" Text="Label"></asp:Label>--%>
        </div>
        <p>&nbsp;</p>
        <hr />
        <br />
    </div>
    
    <p>
        <asp:ObjectDataSource ID="ObjectDataSource1" runat="server" 
            onselecting="ObjectDataSource1_Selecting" SelectMethod="GetThreadData" 
            TypeName="DataAccessLayer.ThreadDataLayer" 
            OldValuesParameterFormatString="original_{0}">
            <SelectParameters>
                <asp:Parameter Name="forumID" Type="Int32" />
                <asp:Parameter Name="subForumID" Type="Int32" />
                <asp:Parameter Name="threadID" Type="Int32" />
            </SelectParameters>
        </asp:ObjectDataSource>
    </p>
    <asp:Repeater ID="Repeater1" runat="server" DataSourceID="ObjectDataSource1">
            <HeaderTemplate>
            </HeaderTemplate>
            
            <ItemTemplate>
                <div class="response1">
                    <h1>RE: <%# Eval("Title") %></h1>
                    <h2>by <%# Eval("Creator")%> - <%# Eval("Time")%></h2>
                    <hr align="left" width="100%">
                    <p><%# Eval("Body").ToString().Replace("\r\n", "<br />") %></p>
                </div>
            </ItemTemplate>
            
            <AlternatingItemTemplate>
                <div class="response2">
                    <h1>RE: <%# Eval("Title") %></h1>
                    <h2>by <%# Eval("Creator")%> - <%# Eval("Time")%></h2>
                    <hr align="left" width="100%">
                    <p><%# Eval("Body").ToString().Replace("\r\n", "<br />") %></p>
                </div>
            </AlternatingItemTemplate>
          
            <SeparatorTemplate>
            </SeparatorTemplate>

          <FooterTemplate>
          </FooterTemplate>

        </asp:Repeater>
    <hr/>
    <h2>Post Reply</h2>
    <asp:Label ID="Label4" runat="server" Text="Title:  "></asp:Label>
    <p>
        <asp:TextBox ID="TextBox3" runat="server" Width="312px"></asp:TextBox>
    </p>
    <p>
        <asp:Label ID="Label5" runat="server" Text="Body:"></asp:Label>
    </p>
    <p>
        <asp:TextBox ID="TextBox4" runat="server" Height="66px" Width="583px" 
            TextMode="MultiLine"></asp:TextBox>
    <asp:Button ID="Button3" runat="server" Text="Post" 
            Style="; margin-left: 100px; margin-top: 0px;" Height="41px" 
            onclick="Button3_Click"/>
        <asp:Label ID="Label6" runat="server"></asp:Label>
    </p>
    <p>
    </p>
</asp:Content>
